<template>
	<view class="page">
    <user-order v-if="isAdmin == 0"></user-order>
    <admin-order v-if="isAdmin == 1"></admin-order>
	</view>
</template>

<script>
import userOrder from '../../components/userOrder/userOrder.vue';
import adminOrder from '../../components/adminOrder/adminOrder.vue';
export default {
  components: {
    userOrder,
    adminOrder
	},
	data() {
		return {
      userId:'',
      isAdmin:0
		};
	},
	onShow() {
    this.userId=uni.getStorageSync('user').data[0].userId
    this.isAdmin = uni.getStorageSync('user').data[0].isAdmin

	},

	methods: {
   
	}
};
</script>

<style lang="scss" scoped>
</style>
